let data = {
  list: [
    {
      menuId: "1",
      menuName: "系统管理",
      menuSort: "1",
      menuType: "1", //菜单类型 1-目录，2-菜单，3-按钮
      menuStatus: "1", //菜单状态 0-不显示，1-显示
      menuIcon: "el-icon-user",
      // parentMenuId: "1",
      // menuUrl: "/add/user",
      createName: "代高成",
      updateName: "代高成",
      createTime: "2022-11-29 10:38:37",
      updateTime: "2022-11-29 10:38:37",
      id: "1"
    },
    {
      menuId: "2",
      menuName: "用户管理",
      menuSort: "2",
      menuType: "1", //菜单类型 1-目录，2-菜单，3-按钮
      menuStatus: "1", //菜单状态 0-不显示，1-显示
      menuIcon: "el-icon-user",
      // parentMenuId: "1",
      // menuUrl: "/add/user",
      createName: "代高成",
      updateName: "代高成",
      createTime: "2022-11-29 10:38:37",
      updateTime: "2022-11-29 10:38:37",
      id: "2"
    },
    {
      menuId: "11",
      menuName: "菜单管理",
      menuSort: "1",
      menuType: "2", //菜单类型 1-目录，2-菜单，3-按钮
      menuStatus: "1", //菜单状态 0-不显示，1-显示
      menuIcon: "el-icon-user",
      parentMenuId: "1",
      menuUrl: "/sys/menus",
      createName: "代高成",
      updateName: "代高成",
      createTime: "2022-11-29 10:38:37",
      updateTime: "2022-11-29 10:38:37",
      id: "11"
    },
    {
      menuId: "12",
      menuName: "角色管理",
      menuSort: "2",
      menuType: "2", //菜单类型 1-目录，2-菜单，3-按钮
      menuStatus: "1", //菜单状态 0-不显示，1-显示
      menuIcon: "el-icon-user",
      parentMenuId: "1",
      menuUrl: "/sys/roles",
      createName: "代高成",
      updateName: "代高成",
      createTime: "2022-11-29 10:38:37",
      updateTime: "2022-11-29 10:38:37",
      id: "12"
    },
    {
      menuId: "21",
      menuName: "用户管理",
      menuSort: "1",
      menuType: "2", //菜单类型 1-目录，2-菜单，3-按钮
      menuStatus: "1", //菜单状态 0-不显示，1-显示
      menuIcon: "el-icon-user",
      parentMenuId: "2",
      menuUrl: "/user/userInfo",
      createName: "代高成",
      updateName: "代高成",
      createTime: "2022-11-29 10:38:37",
      updateTime: "2022-11-29 10:38:37",
      id: "21"
    },
    {
      menuId: "22",
      menuName: "学生管理",
      menuSort: "2",
      menuType: "2", //菜单类型 1-目录，2-菜单，3-按钮
      menuStatus: "1", //菜单状态 0-不显示，1-显示
      menuIcon: "el-icon-user",
      parentMenuId: "2",
      menuUrl: "/user/studentInfo",
      createName: "代高成",
      updateName: "代高成",
      createTime: "2022-11-29 10:38:37",
      updateTime: "2022-11-29 10:38:37",
      id: "22"
    },
    {
      menuId: "23",
      menuName: "教师管理",
      menuSort: "1",
      menuType: "2", //菜单类型 1-目录，2-菜单，3-按钮
      menuStatus: "0", //菜单状态 0-不显示，1-显示
      menuIcon: "el-icon-user",
      parentMenuId: "2",
      menuUrl: "/user/teacherInfo",
      createName: "代高成",
      updateName: "代高成",
      createTime: "2022-11-29 10:38:37",
      updateTime: "2022-11-29 10:38:37",
      id: "23"
    }
  ]
};

module.exports = [
  //菜单列表
  {
    url: "/system/menu/getMenuList",
    type: "post",
    response: config => {
      //参数  config.body
      const { pageIndex = 1, pageSize = 10 } = config.body;
      data.pageIndex = pageIndex;
      data.pageSize = pageSize;
      return {
        statusCode: 200,
        data: data,
        msg: "OK"
      };
    }
  },

  //添加菜单
  {
    url: "/system/menu/addMenu",
    type: "post",
    response: config => {
      //参数  config.body
      const menus = config.body.menus;
      // console.log('add',menus);
      return {
        statusCode: "200",
        msg: "成功",
        data: []
      };
    }
  },

  //更新菜单
  {
    url: "/system/menu/updateMenu",
    type: "post",
    response: config => {
      //参数  config.body
      const menus = config.body.menus;
      console.log('update', menus);
      return {
        statusCode: "200",
        msg: "成功",
        data: []
      };
    }
  },


  //删除菜单
  {
    url: "/system/menu/deleteMenu",
    type: "post",
    response: config => {
      //参数  config.body
      const id = config.body.id;
      // console.log('del',id);
      return {
        statusCode: "200",
        msg: "成功",
        data: []
      };
    }
  }
];
